if (ni >= t0 + 1 && nj >= t1 + 1)
  for (int c2 = 0; c2 <= min(15, nk - 1); c2 += 1) {
    S_1(t0, t1, c2);
    if (nj >= t1 + 17) {
      S_1(t0, t1 + 16, c2);
      if (nj >= t1 + 33) {
        S_1(t0, t1 + 32, c2);
        if (nj >= t1 + 49)
          S_1(t0, t1 + 48, c2);
      }
    }
    if (ni >= t0 + 17) {
      S_1(t0 + 16, t1, c2);
      if (nj >= t1 + 17) {
        S_1(t0 + 16, t1 + 16, c2);
        if (nj >= t1 + 33) {
          S_1(t0 + 16, t1 + 32, c2);
          if (nj >= t1 + 49)
            S_1(t0 + 16, t1 + 48, c2);
        }
      }
      if (ni >= t0 + 33) {
        S_1(t0 + 32, t1, c2);
        if (nj >= t1 + 17) {
          S_1(t0 + 32, t1 + 16, c2);
          if (nj >= t1 + 33) {
            S_1(t0 + 32, t1 + 32, c2);
            if (nj >= t1 + 49)
              S_1(t0 + 32, t1 + 48, c2);
          }
        }
        if (ni >= t0 + 49) {
          S_1(t0 + 48, t1, c2);
          if (nj >= t1 + 17) {
            S_1(t0 + 48, t1 + 16, c2);
            if (nj >= t1 + 33) {
              S_1(t0 + 48, t1 + 32, c2);
              if (nj >= t1 + 49)
                S_1(t0 + 48, t1 + 48, c2);
            }
          }
        }
      }
    }
  }
